<template>
  <div class="admission">
    <!-- 门票 -->
    <!-- 景点门票 -->
    <div class="ticket">
      <div class="up">
        <span>票</span>
        <p>景点门票</p>
      </div>
      <div class="down">
        <p>今日出游</p>
        <p>明日出游</p>
        <p>指定日期</p>
      </div>
    </div>
    <!-- 唐楼 -->
    <div class="house">
      <p class="guitang">簋唐楼</p>
      <div>
        <p>52%游客购买</p>
        <p>已售187</p>
      </div>
    </div>
    <!-- 平日看看票 -->
    <!-- mock数据  Sticket-->
    <div class="watchbox">
      <div class="watch" v-for="(v, i) in arr" :key="i">
        <div class="left">
          <h6>{{ v.tittle1 }}</h6>
          <p class="gm">{{ v.tittle2 }}</p>
          <p class="gf">
            {{ v.tittle3 }} <span class="line">|</span> {{ v.tittle4 }}
          </p>
          <p class="ys">
            <span>{{ v.tittle5 }}</span
            ><span class="line">|</span>
            <span class="xz">{{ v.tittle6 }}</span>
          </p>
        </div>
        <div class="right">
          <p class="price">
            <span class="iconfont icon-wenhao"></span>
            <span class="num">￥59</span>
            <span class="nums">{{ v.tittle7 }}</span
            >起
          </p>
          <p class="yd" @click="fun()">预定</p>
        </div>
      </div>
    </div>

    <!-- 更多门票 -->
    <div class="ticketbox">
      <div class="moreticket">更多9个门票</div>
    </div>
    <!-- 灰色条 -->
    <div class="grey"></div>
    <!-- 套餐 -->
    <div class="packbox">
      <div class="package">
        <div class="left">
          <p>套餐</p>
          <h5>门票+酒店</h5>
        </div>
        <div class="right">￥312起</div>
      </div>
    </div>

    <!-- 灰色条 -->
    <div class="grey"></div>
    <!-- 参团 -->
    <div class="delegation">
      <div class="package">
        <div class="left">
          <p>参团</p>
          <h5>跟团游</h5>
        </div>
        <div class="right">￥150起</div>
      </div>
    </div>
    <!-- 灰色条 -->
    <div class="grey"></div>
  </div>
</template>

<script>
import axios from "axios";
export default {
  data() {
    return {
      arr: [],
    };
  },
  mounted() {
    axios.request("http://localhost:8889/Sticket").then((ok) => {
      console.log(ok);
      this.arr = ok.data;
    });
  },
  methods: {
    fun() {
      this.$router.push("/orderlist");
    },
  },
};
</script>

<style lang="scss" scoped>
* {
  margin: 0;
  padding: 0;
}
.admission {
  width: 100%;
  margin-top: 5.333vw;
  // background-color: red;
  .up {
    width: 22.133vw;
    height: 6.667vw;
    display: flex;
    justify-content: space-between;
    margin-left: 1.867vw;
    span {
      display: block;
      width: 4.267vw;
      height: 4.267vw;
      background-color: orange;
      text-align: center;
      font-size: 2.667vw;
      line-height: 4.267vw;
      color: white;
      margin-top: 0.8vw;
    }
    p {
      font-weight: bold;
    }
  }
  .down {
    width: 72.8vw;
    font-size: 2.933vw;
    display: flex;
    justify-content: space-around;
    p {
      width: 21.6vw;
      height: 7.2vw;
      border-radius: 3.467vw;
      text-align: center;
      line-height: 7.2vw;
      background-color: #f6f6f6;
    }
  }
}
.house {
  width: 100%;
  .guitang {
    margin: 4.267vw 0 0 1.333vw;
  }
  div {
    width: 37.6vw;
    display: flex;
    justify-content: space-around;
    font-size: 3.467vw;
    p:nth-child(1) {
      width: 22.4vw;
      height: 4.533vw;
      background-color: #f6f6f6;
      text-align: center;
      line-height: 4.533vw;
      margin: 2.4vw 0 0 1.333vw;
    }
    p:nth-child(2) {
      width: 13.6vw;
      height: 4.533vw;
      background-color: #f6f6f6;
      text-align: center;
      line-height: 4.533vw;
      margin-top: 2.4vw;
    }
  }
}
.watchbox {
  width: 100%;
  .watch {
    margin: auto;
    width: 89.6vw;
    height: 21.867vw;
    display: flex;
    justify-content: space-around;
    margin-top: 3.733vw;
    line-height: 4.8vw;
    border-bottom: 0.107vw solid #d7d7d7;
    .left {
      .gm {
        color: #1e5aab;
        font-size: 2.667vw;
      }
      .gf {
        color: #64707f;
        font-size: 2.667vw;
        .line {
          margin: 0 1.333vw;
        }
      }
      .ys {
        color: #64707f;
        font-size: 2.667vw;
        .line {
          margin: 0 1.333vw;
        }
        .xz {
          color: #1e5aab;
        }
      }
    }
    .right {
      margin-top: 2.4vw;
      .price {
        color: #b4b4b4;
        font-size: 2.667vw;
        .num {
          text-decoration: line-through;
        }
        .nums {
          font-size: 5.333vw;
          color: #f94508;
        }
      }
      .yd {
        width: 14.133vw;
        height: 6.133vw;
        background-color: #f94508;
        color: #f6f6f6;
        text-align: center;
        line-height: 6.133vw;
        margin: auto;
        border-radius: 2.933vw;
        font-size: 3.467vw;
        margin-top: 2.4vw;
      }
    }
  }
}
.ticketbox {
  width: 100%;
  .moreticket {
    width: 89.6vw;
    height: 8.8vw;
    margin: auto;
    // background-color: red;
    text-align: center;
    line-height: 8.8vw;
    font-size: 3.2vw;
  }
}
.grey {
  width: 100%;
  height: 2.133vw;
  background-color: #f6f6f6;
}
.packbox {
  width: 100%;
  .package {
    margin: auto;
    width: 92vw;
    height: 13.333vw;
    display: flex;
    justify-content: space-between;
    line-height: 13.333vw;
    .left {
      display: flex;
      p {
        width: 6.933vw;
        height: 4vw;
        background-color: #f29523;
        text-align: center;
        line-height: 4vw;
        font-size: 2.4vw;
        margin: 4.533vw 0.8vw 0 0;
        color: #f6f6f6;
      }
    }
    .right {
      color: #ec7039;
      font-weight: bold;
      font-size: 3.467vw;
    }
  }
}
.delegation {
  width: 100%;
  .package {
    margin: auto;
    width: 92vw;
    height: 13.333vw;
    display: flex;
    justify-content: space-between;
    line-height: 13.333vw;
    .left {
      display: flex;
      p {
        width: 6.933vw;
        height: 4vw;
        background-color: #f07036;
        text-align: center;
        line-height: 4vw;
        font-size: 2.4vw;
        margin: 4.533vw 0.8vw 0 0;
        color: #f6f6f6;
      }
    }
    .right {
      color: #ec7039;
      font-weight: bold;
      font-size: 3.467vw;
    }
  }
}
</style>